import type { RouteRecordRaw } from 'vue-router'

// 必要路由
export const requiredRoutes: RouteRecordRaw[] = [
  {
    path: '/',
    name: 'Layout',
    component: () => import('@/views/Layout.vue'),
    redirect: '/home',
    children: [{ path: 'home', name: 'Home', component: () => import('@/views/Home.vue'), meta: {
      requiresAuth: false
    }}],
  },

  {
    path: '/login',
    name: 'Login',
    component: () => import('@/views/Login.vue'),
  },
  {
    path: '/404',
    name: 'NotFound',
    component: () => import('@/views/NotFound.vue'),
  },
  {
    path: '/:pathMatch(.*)*', // 匹配任意未定义路径
    redirect: '/404'
  },
]

// 动态路由（根据用户权限数据匹配过滤）
export const menumRoutes: RouteRecordRaw[] = []
